import 'package:flutter/material.dart'; 
class DrawerPage extends StatefulWidget {
  DrawerPage({Key key}) : super(key: key);

  _DrawerPageState createState() => _DrawerPageState();
}

class _DrawerPageState extends State<DrawerPage> {
  @override
  Widget build(BuildContext context) {
     return Scaffold(
       floatingActionButton: FloatingActionButton(
        child: Text("Back"),
        onPressed: (){
          Navigator.of(context).pop();
        },
      ),
       appBar: AppBar(
         title: Text("DrawerPage"),
       ),
       drawer: Drawer(
         child: Column(
           children: <Widget>[
             Row(
               children: <Widget>[
                 Expanded(
                   child: DrawerHeader(
                      child: Text("DrawerHeader"),
                      decoration: BoxDecoration(
                        color: Colors.green,
                        image: DecorationImage(
                          image: NetworkImage("https://www.itying.com/images/flutter/2.png"),
                          fit: BoxFit.cover
                        ),
                      ),
                    ),
                 )
               ],
             ),
             ListTile(
               leading: CircleAvatar(child: Icon(Icons.pages),),
               title: Text("left"),
             ),
             Divider()
           ],
         ),
       ),
       endDrawer: Drawer(
         child: Column(
           children: <Widget>[
             Row(
               children: <Widget>[
                 Expanded(
                   child: UserAccountsDrawerHeader(
                      accountName: Text("name"),
                      accountEmail: Text("@qq.com"),
                      currentAccountPicture: CircleAvatar(
                        backgroundImage: NetworkImage("https://www.itying.com/images/flutter/2.png"),
                      ),
                      otherAccountsPictures: <Widget>[
                        Image.network("https://www.itying.com/images/flutter/1.png"),
                        Image.network("https://www.itying.com/images/flutter/2.png"),
                      ],
                   ),
                 )
               ],
             ),
             ListTile(
               leading: CircleAvatar(child: Icon(Icons.pages),),
               title: Text("right"),
             ),
             Divider()
           ],
         ),
       ),
    );
  }
}